//package org.iteam.core.utils;
//
///**
// * 
// */
//
//import java.io.InputStream;
//import java.io.OutputStreamWriter;
//import java.io.PrintWriter;
//import java.net.HttpURLConnection;
//import java.net.URL;
//
///**
// * @Title: JavaNet.java
// * @Description:
// * @author Wangchaoyong
// * @date 上午9:08:05
// * @version V1.0
// */
//public class JavaNet {
//	public static String service(String httpUrl1, String params)
//			throws Exception {
//		try {
//			URL url = new URL(httpUrl1);
//			HttpURLConnection conn = (HttpURLConnection) url.openConnection();
//			conn.setDoInput(true);
//			conn.setDoOutput(true);
//			conn.setRequestMethod("POST");
//			conn.setRequestProperty("User-Agent",
//					"Mozilla/4.0 (compatible; MSIE 5.0; Windows NT; DigExt)");
//			PrintWriter out = new PrintWriter(new OutputStreamWriter(
//					conn.getOutputStream(), "utf-8"));
//			out.print(params);
//			out.flush();
//			out.close();
//			InputStream is = conn.getInputStream();
//			byte buffer[] = new byte[is.available()];
//			StringBuffer sb = new StringBuffer();
//			int i = 0;
//			while ((i = is.read(buffer)) != -1) {
//				sb.append(new String(buffer, 0, i, "UTF-8"));
//			}
//			return sb.toString();
//		} catch (Exception e) {
//			return "error";
//		}
//	}
//
//	public static void main(String[] args) throws Exception {
//	}
//}
